home *** CD-ROM | disk | FTP | other *** search
/ Inside Magic / Inside Magic.iso / mac / Inside Magic™ / Inside Magic™.dxr / 01843_Movie Controls.ls < prev    next >
Encoding:
Text File  |  1995-09-28  |  1.3 KB  |  36 lines

  1. on backMovie
  2.   global gMoviePixel, gMoviePos, speed, gHalfLength, gMooVChan, gMode
  3.   puppetSprite(3, 1)
  4.   if (the castType of cast the castNum of sprite gMooVChan = #digitalVideo) and (the duration of cast the castNum of sprite gMooVChan > 0) then
  5.     if gMode = 0 then
  6.       set the movieRate of sprite gMooVChan to 0
  7.       set the movieTime of sprite gMooVChan to 0
  8.     else
  9.       set the movieRate of sprite gMooVChan to 0
  10.       set the movieTime of sprite gMooVChan to gHalfLength + 4
  11.     end if
  12.     updateStage()
  13.   else
  14.     alert("'Inside Magic' is having problems running QuickTime on your computer.  This might be due to insufficient memory.  Please exit the program and allocate more memory to 'Inside Magic.'")
  15.     allSpritesOff()
  16.     homeBaseInit()
  17.     abort()
  18.   end if
  19. end
  20.  
  21. on GetMooVFrame
  22.   global gMode, gBallSlid, gHalfLength, gFullLength, gSliderLength, gMovieBegin, gMovieEnd, gMooVChan, gMoviePixel, gCatchTicks
  23.   if gMode = 0 then
  24.     set newTime to integer(gBallSlid / gMoviePixel)
  25.   else
  26.     set newTime to integer((gBallSlid / gMoviePixel) + gHalfLength)
  27.   end if
  28.   if newTime < gMovieBegin then
  29.     set newTime to gMovieBegin
  30.   end if
  31.   if newTime > gMovieEnd then
  32.     set newTime to gMovieEnd
  33.   end if
  34.   set the movieTime of sprite gMooVChan to newTime
  35. end
  36.